<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.14"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>libslic3r: src/libslic3r/IO.hpp Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="Slic3r_192px_transparent.png"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">libslic3r
   </div>
   <div id="projectbrief">Library for generating gcode from 3d models</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.14 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a class="el" href="dir_f69e6fbaea45487e96bc9ed8ccf9ff8f.html">libslic3r</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="headertitle">
<div class="title">IO.hpp</div>  </div>
</div><!--header-->
<div class="contents">
<a href="_i_o_8hpp.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;<span class="preprocessor">#ifndef slic3r_IO_hpp_</span></div><div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;<span class="preprocessor">#define slic3r_IO_hpp_</span></div><div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160;</div><div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;<span class="preprocessor">#include &quot;<a class="code" href="libslic3r_8h.html">libslic3r.h</a>&quot;</span></div><div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160;<span class="preprocessor">#include &quot;<a class="code" href="_model_8hpp.html">Model.hpp</a>&quot;</span></div><div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;<span class="preprocessor">#include &quot;<a class="code" href="_triangle_mesh_8hpp.html">TriangleMesh.hpp</a>&quot;</span></div><div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;<span class="preprocessor">#include &lt;string&gt;</span></div><div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;</div><div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;<span class="keyword">namespace </span><a class="code" href="namespace_slic3r.html">Slic3r</a> { <span class="keyword">namespace </span>IO {</div><div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;</div><div class="line"><a name="l00011"></a><span class="lineno"><a class="line" href="class_slic3r_1_1_i_o_1_1_s_t_l.html">   11</a></span>&#160;<span class="keyword">class </span><a class="code" href="class_slic3r_1_1_i_o_1_1_s_t_l.html">STL</a></div><div class="line"><a name="l00012"></a><span class="lineno">   12</span>&#160;{</div><div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160;    <span class="keyword">public</span>:</div><div class="line"><a name="l00014"></a><span class="lineno">   14</span>&#160;    <span class="keyword">static</span> <span class="keywordtype">bool</span> <a class="code" href="class_slic3r_1_1_i_o_1_1_s_t_l.html#ae3cf8cdb3c9ddd78a156d8e8ca772372">read</a>(std::string input_file, <a class="code" href="class_slic3r_1_1_triangle_mesh.html">TriangleMesh</a>* mesh);</div><div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;    <span class="keyword">static</span> <span class="keywordtype">bool</span> <a class="code" href="class_slic3r_1_1_i_o_1_1_s_t_l.html#ae3cf8cdb3c9ddd78a156d8e8ca772372">read</a>(std::string input_file, <a class="code" href="class_slic3r_1_1_model.html">Model</a>* model);</div><div class="line"><a name="l00016"></a><span class="lineno">   16</span>&#160;    <span class="keyword">static</span> <span class="keywordtype">bool</span> <a class="code" href="class_slic3r_1_1_i_o_1_1_s_t_l.html#ae371d334230ee0ba01ad0a754961f4e1">write</a>(<a class="code" href="class_slic3r_1_1_model.html">Model</a>&amp; model, std::string output_file, <span class="keywordtype">bool</span> binary = <span class="keyword">true</span>);</div><div class="line"><a name="l00017"></a><span class="lineno">   17</span>&#160;    <span class="keyword">static</span> <span class="keywordtype">bool</span> <a class="code" href="class_slic3r_1_1_i_o_1_1_s_t_l.html#ae371d334230ee0ba01ad0a754961f4e1">write</a>(<a class="code" href="class_slic3r_1_1_triangle_mesh.html">TriangleMesh</a>&amp; mesh, std::string output_file, <span class="keywordtype">bool</span> binary = <span class="keyword">true</span>);</div><div class="line"><a name="l00018"></a><span class="lineno">   18</span>&#160;};</div><div class="line"><a name="l00019"></a><span class="lineno">   19</span>&#160;</div><div class="line"><a name="l00020"></a><span class="lineno"><a class="line" href="class_slic3r_1_1_i_o_1_1_o_b_j.html">   20</a></span>&#160;<span class="keyword">class </span><a class="code" href="class_slic3r_1_1_i_o_1_1_o_b_j.html">OBJ</a></div><div class="line"><a name="l00021"></a><span class="lineno">   21</span>&#160;{</div><div class="line"><a name="l00022"></a><span class="lineno">   22</span>&#160;    <span class="keyword">public</span>:</div><div class="line"><a name="l00023"></a><span class="lineno">   23</span>&#160;    <span class="keyword">static</span> <span class="keywordtype">bool</span> <a class="code" href="class_slic3r_1_1_i_o_1_1_o_b_j.html#aab90cb5f4d5b318bdd25d342107f21c6">read</a>(std::string input_file, <a class="code" href="class_slic3r_1_1_triangle_mesh.html">TriangleMesh</a>* mesh);</div><div class="line"><a name="l00024"></a><span class="lineno">   24</span>&#160;    <span class="keyword">static</span> <span class="keywordtype">bool</span> <a class="code" href="class_slic3r_1_1_i_o_1_1_o_b_j.html#aab90cb5f4d5b318bdd25d342107f21c6">read</a>(std::string input_file, <a class="code" href="class_slic3r_1_1_model.html">Model</a>* model);</div><div class="line"><a name="l00025"></a><span class="lineno">   25</span>&#160;    <span class="keyword">static</span> <span class="keywordtype">bool</span> <a class="code" href="class_slic3r_1_1_i_o_1_1_o_b_j.html#a12e26d7922b73df120b99e36a97645a1">write</a>(<a class="code" href="class_slic3r_1_1_model.html">Model</a>&amp; model, std::string output_file);</div><div class="line"><a name="l00026"></a><span class="lineno">   26</span>&#160;    <span class="keyword">static</span> <span class="keywordtype">bool</span> <a class="code" href="class_slic3r_1_1_i_o_1_1_o_b_j.html#a12e26d7922b73df120b99e36a97645a1">write</a>(<a class="code" href="class_slic3r_1_1_triangle_mesh.html">TriangleMesh</a>&amp; mesh, std::string output_file);</div><div class="line"><a name="l00027"></a><span class="lineno">   27</span>&#160;};</div><div class="line"><a name="l00028"></a><span class="lineno">   28</span>&#160;</div><div class="line"><a name="l00029"></a><span class="lineno"><a class="line" href="class_slic3r_1_1_i_o_1_1_a_m_f.html">   29</a></span>&#160;<span class="keyword">class </span><a class="code" href="class_slic3r_1_1_i_o_1_1_a_m_f.html">AMF</a></div><div class="line"><a name="l00030"></a><span class="lineno">   30</span>&#160;{</div><div class="line"><a name="l00031"></a><span class="lineno">   31</span>&#160;    <span class="keyword">public</span>:</div><div class="line"><a name="l00032"></a><span class="lineno">   32</span>&#160;    <span class="keyword">static</span> <span class="keywordtype">bool</span> <a class="code" href="class_slic3r_1_1_i_o_1_1_a_m_f.html#ac98944fb28e179f17f8950f518c54edf">read</a>(std::string input_file, <a class="code" href="class_slic3r_1_1_model.html">Model</a>* model);</div><div class="line"><a name="l00033"></a><span class="lineno">   33</span>&#160;    <span class="keyword">static</span> <span class="keywordtype">bool</span> <a class="code" href="class_slic3r_1_1_i_o_1_1_a_m_f.html#a21547db6d3cfd8206329af9dffb95dca">write</a>(<a class="code" href="class_slic3r_1_1_model.html">Model</a>&amp; model, std::string output_file);</div><div class="line"><a name="l00034"></a><span class="lineno">   34</span>&#160;};</div><div class="line"><a name="l00035"></a><span class="lineno">   35</span>&#160;</div><div class="line"><a name="l00036"></a><span class="lineno"><a class="line" href="class_slic3r_1_1_i_o_1_1_p_o_v.html">   36</a></span>&#160;<span class="keyword">class </span><a class="code" href="class_slic3r_1_1_i_o_1_1_p_o_v.html">POV</a></div><div class="line"><a name="l00037"></a><span class="lineno">   37</span>&#160;{</div><div class="line"><a name="l00038"></a><span class="lineno">   38</span>&#160;    <span class="keyword">public</span>:</div><div class="line"><a name="l00039"></a><span class="lineno">   39</span>&#160;    <span class="keyword">static</span> <span class="keywordtype">bool</span> <a class="code" href="class_slic3r_1_1_i_o_1_1_p_o_v.html#ad32abb0ac8bb3872340eca446bd8e5f6">write</a>(<a class="code" href="class_slic3r_1_1_triangle_mesh.html">TriangleMesh</a>&amp; mesh, std::string output_file);</div><div class="line"><a name="l00040"></a><span class="lineno">   40</span>&#160;};</div><div class="line"><a name="l00041"></a><span class="lineno">   41</span>&#160;</div><div class="line"><a name="l00042"></a><span class="lineno"><a class="line" href="class_slic3r_1_1_i_o_1_1_t_m_f.html">   42</a></span>&#160;<span class="keyword">class </span><a class="code" href="class_slic3r_1_1_i_o_1_1_t_m_f.html">TMF</a></div><div class="line"><a name="l00043"></a><span class="lineno">   43</span>&#160;{</div><div class="line"><a name="l00044"></a><span class="lineno">   44</span>&#160;    <span class="keyword">public</span>:</div><div class="line"><a name="l00045"></a><span class="lineno">   45</span>&#160;    <span class="keyword">static</span> <span class="keywordtype">bool</span> <a class="code" href="class_slic3r_1_1_i_o_1_1_t_m_f.html#a381856fcee9c07e8738cbfce98adab0c">read</a>(std::string input_file, <a class="code" href="class_slic3r_1_1_model.html">Model</a>* model);</div><div class="line"><a name="l00046"></a><span class="lineno">   46</span>&#160;    <span class="keyword">static</span> <span class="keywordtype">bool</span> <a class="code" href="class_slic3r_1_1_i_o_1_1_t_m_f.html#af034300e641abca5720606d7d3aa670c">write</a>(<a class="code" href="class_slic3r_1_1_model.html">Model</a>&amp; model, std::string output_file);</div><div class="line"><a name="l00047"></a><span class="lineno">   47</span>&#160;};</div><div class="line"><a name="l00048"></a><span class="lineno">   48</span>&#160;</div><div class="line"><a name="l00049"></a><span class="lineno">   49</span>&#160;} }</div><div class="line"><a name="l00050"></a><span class="lineno">   50</span>&#160;</div><div class="line"><a name="l00051"></a><span class="lineno">   51</span>&#160;<span class="preprocessor">#endif</span></div><div class="ttc" id="libslic3r_8h_html"><div class="ttname"><a href="libslic3r_8h.html">libslic3r.h</a></div></div>
<div class="ttc" id="class_slic3r_1_1_i_o_1_1_t_m_f_html_af034300e641abca5720606d7d3aa670c"><div class="ttname"><a href="class_slic3r_1_1_i_o_1_1_t_m_f.html#af034300e641abca5720606d7d3aa670c">Slic3r::IO::TMF::write</a></div><div class="ttdeci">static bool write(Model &amp;model, std::string output_file)</div><div class="ttdef"><b>Definition:</b> TMF.cpp:391</div></div>
<div class="ttc" id="class_slic3r_1_1_i_o_1_1_s_t_l_html"><div class="ttname"><a href="class_slic3r_1_1_i_o_1_1_s_t_l.html">Slic3r::IO::STL</a></div><div class="ttdef"><b>Definition:</b> IO.hpp:11</div></div>
<div class="ttc" id="class_slic3r_1_1_i_o_1_1_a_m_f_html_ac98944fb28e179f17f8950f518c54edf"><div class="ttname"><a href="class_slic3r_1_1_i_o_1_1_a_m_f.html#ac98944fb28e179f17f8950f518c54edf">Slic3r::IO::AMF::read</a></div><div class="ttdeci">static bool read(std::string input_file, Model *model)</div><div class="ttdef"><b>Definition:</b> AMF.cpp:451</div></div>
<div class="ttc" id="class_slic3r_1_1_i_o_1_1_o_b_j_html_a12e26d7922b73df120b99e36a97645a1"><div class="ttname"><a href="class_slic3r_1_1_i_o_1_1_o_b_j.html#a12e26d7922b73df120b99e36a97645a1">Slic3r::IO::OBJ::write</a></div><div class="ttdeci">static bool write(Model &amp;model, std::string output_file)</div><div class="ttdef"><b>Definition:</b> IO.cpp:137</div></div>
<div class="ttc" id="class_slic3r_1_1_i_o_1_1_o_b_j_html"><div class="ttname"><a href="class_slic3r_1_1_i_o_1_1_o_b_j.html">Slic3r::IO::OBJ</a></div><div class="ttdef"><b>Definition:</b> IO.hpp:20</div></div>
<div class="ttc" id="class_slic3r_1_1_i_o_1_1_p_o_v_html"><div class="ttname"><a href="class_slic3r_1_1_i_o_1_1_p_o_v.html">Slic3r::IO::POV</a></div><div class="ttdef"><b>Definition:</b> IO.hpp:36</div></div>
<div class="ttc" id="class_slic3r_1_1_i_o_1_1_a_m_f_html_a21547db6d3cfd8206329af9dffb95dca"><div class="ttname"><a href="class_slic3r_1_1_i_o_1_1_a_m_f.html#a21547db6d3cfd8206329af9dffb95dca">Slic3r::IO::AMF::write</a></div><div class="ttdeci">static bool write(Model &amp;model, std::string output_file)</div><div class="ttdef"><b>Definition:</b> AMF.cpp:499</div></div>
<div class="ttc" id="class_slic3r_1_1_model_html"><div class="ttname"><a href="class_slic3r_1_1_model.html">Slic3r::Model</a></div><div class="ttdef"><b>Definition:</b> Model.hpp:38</div></div>
<div class="ttc" id="class_slic3r_1_1_i_o_1_1_s_t_l_html_ae371d334230ee0ba01ad0a754961f4e1"><div class="ttname"><a href="class_slic3r_1_1_i_o_1_1_s_t_l.html#ae371d334230ee0ba01ad0a754961f4e1">Slic3r::IO::STL::write</a></div><div class="ttdeci">static bool write(Model &amp;model, std::string output_file, bool binary=true)</div><div class="ttdef"><b>Definition:</b> IO.cpp:47</div></div>
<div class="ttc" id="class_slic3r_1_1_i_o_1_1_s_t_l_html_ae3cf8cdb3c9ddd78a156d8e8ca772372"><div class="ttname"><a href="class_slic3r_1_1_i_o_1_1_s_t_l.html#ae3cf8cdb3c9ddd78a156d8e8ca772372">Slic3r::IO::STL::read</a></div><div class="ttdeci">static bool read(std::string input_file, TriangleMesh *mesh)</div><div class="ttdef"><b>Definition:</b> IO.cpp:14</div></div>
<div class="ttc" id="class_slic3r_1_1_i_o_1_1_o_b_j_html_aab90cb5f4d5b318bdd25d342107f21c6"><div class="ttname"><a href="class_slic3r_1_1_i_o_1_1_o_b_j.html#aab90cb5f4d5b318bdd25d342107f21c6">Slic3r::IO::OBJ::read</a></div><div class="ttdeci">static bool read(std::string input_file, TriangleMesh *mesh)</div><div class="ttdef"><b>Definition:</b> IO.cpp:65</div></div>
<div class="ttc" id="namespace_slic3r_html"><div class="ttname"><a href="namespace_slic3r.html">Slic3r</a></div><div class="ttdef"><b>Definition:</b> BoundingBox.cpp:4</div></div>
<div class="ttc" id="_model_8hpp_html"><div class="ttname"><a href="_model_8hpp.html">Model.hpp</a></div></div>
<div class="ttc" id="class_slic3r_1_1_i_o_1_1_a_m_f_html"><div class="ttname"><a href="class_slic3r_1_1_i_o_1_1_a_m_f.html">Slic3r::IO::AMF</a></div><div class="ttdef"><b>Definition:</b> IO.hpp:29</div></div>
<div class="ttc" id="class_slic3r_1_1_i_o_1_1_t_m_f_html_a381856fcee9c07e8738cbfce98adab0c"><div class="ttname"><a href="class_slic3r_1_1_i_o_1_1_t_m_f.html#a381856fcee9c07e8738cbfce98adab0c">Slic3r::IO::TMF::read</a></div><div class="ttdeci">static bool read(std::string input_file, Model *model)</div><div class="ttdef"><b>Definition:</b> TMF.cpp:398</div></div>
<div class="ttc" id="class_slic3r_1_1_i_o_1_1_p_o_v_html_ad32abb0ac8bb3872340eca446bd8e5f6"><div class="ttname"><a href="class_slic3r_1_1_i_o_1_1_p_o_v.html#ad32abb0ac8bb3872340eca446bd8e5f6">Slic3r::IO::POV::write</a></div><div class="ttdeci">static bool write(TriangleMesh &amp;mesh, std::string output_file)</div><div class="ttdef"><b>Definition:</b> IO.cpp:151</div></div>
<div class="ttc" id="_triangle_mesh_8hpp_html"><div class="ttname"><a href="_triangle_mesh_8hpp.html">TriangleMesh.hpp</a></div></div>
<div class="ttc" id="class_slic3r_1_1_triangle_mesh_html"><div class="ttname"><a href="class_slic3r_1_1_triangle_mesh.html">Slic3r::TriangleMesh</a></div><div class="ttdef"><b>Definition:</b> TriangleMesh.hpp:20</div></div>
<div class="ttc" id="class_slic3r_1_1_i_o_1_1_t_m_f_html"><div class="ttname"><a href="class_slic3r_1_1_i_o_1_1_t_m_f.html">Slic3r::IO::TMF</a></div><div class="ttdef"><b>Definition:</b> IO.hpp:42</div></div>
</div><!-- fragment --></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.14
</small></address>
</body>
</html>
